<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/4/23
 * Time: 15:23
 */

namespace app\models;

use yii;
use yii\db\Query;


class ExchangeModel extends BaseModel
{
    public function __construct()
    {
        $this->table = yii::$app->db->tablePrefix . 'exchange_reate';
    }

    public function one($where = [])
    {
        // TODO: Implement one() method.
    }

    public function all($where = [], $offset = false, $limit = false, $order = false)
    {
        $db = new Query();
        return $db->select('*')->from($this->table)->orderBy(['month' => SORT_DESC])->all();
    }

}